package com.turing.post.report.util;

import java.math.BigInteger;
import java.util.Date;


import javax.ejb.Local;
import javax.ejb.Remote;

import com.turing.post.util.PCPSApplicationException;


/**
 * 商户手续费追溯明细表
 * @author YangShuo
 *
 */
@Remote
@Local
public interface MerchantPastIncomeDetailDao {

	/**
	 * 获取某商户某日的S追溯总额
	 * @param merchantNo
	 * @param tranDate
	 */
	public BigInteger getTotalSIncomeByMerchantNo_Trandate_Salbranchno(String merchantNo, Date tranDate,String SaleBranchNo);
	
	/**
	 * 获取某商户某日的M追溯总额
	 * @param merchantNo
	 * @param tranDate
	 */
	public BigInteger getTotalMIncomeByMerchantNo_Trandate_Salbranchno(String merchantNo, Date tranDate,String SaleBranchNo);
	
	/**
	 * 根据商户号，时间段，得到某段时间的收入总额
	 * 
	 * @param merchantno
	 * @param startdate
	 * @param enddate
	 * @return
	 */
	
	public Long getAllIncomeByDate(String merchantno, Date startdate,
			Date enddate);
	
	/**
	 * 新增操作
	 * @param mpid
	 * @throws PCPSApplicationException
	 */
	public void insertMerchantPastIncomeDetail(MerchantPastIncomeDetail mpid)	throws PCPSApplicationException;
	
}
